package com.example.springmvc;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

@RequestMapping("user1")
@RestController
public class UserController1 {
@RequestMapping(value = "/t1",method ={RequestMethod.GET,RequestMethod.POST} )
    public String t1(){
        return "hello world";
    }

    @GetMapping("/t2")
    public String t2(){
    return "GetMappiing";
    }

    @PostMapping("/t3")
    public String t3(){
    return "PostMapping";
    }

    @RequestMapping("t4")
    public String t4(String name){
    return name;
    }

    @RequestMapping("/t5")
    public Integer  t5(Integer age){
    return age;
    }

    @RequestMapping("/t6")
    public int t6(int age){
        return age;
    }


}
